package com.yaodian100.ec.member.entity;

import java.math.BigDecimal;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import org.hibernate.annotations.GenericGenerator;

import com.yaodian100.core.common.entity.BaseEntity;

@Entity
@Table(name = "EC_MEMBER_BALANCE")
public class Balance extends BaseEntity {

	private static final long serialVersionUID = 8485866552563691137L;

	/**
	 * 會員編號
	 */
	@Id
	@GeneratedValue(generator = "assigned")
	@GenericGenerator(name = "assigned", strategy = "assigned")
	@Column(name = "MEMBER_ID", nullable = false, length = 10)
	private String memberID;

	/**
	 * 購物金結餘
	 */
	@Column(name = "BONUS_BALANCE", columnDefinition = "numeric(10,2)")
	private BigDecimal bonusBalance;

	/**
	 * 積點結餘
	 */
	@Column(name = "POINT_BALANCE", columnDefinition = "numeric(10,2)")
	private BigDecimal pointBalance;

	/**
	 * 禮品卡結餘
	 */
	@Column(name = "GIFT_CARD_BALANCE", columnDefinition = "numeric(10,2)")
	private BigDecimal giftcardBalance;

	/**
	 * 我的虛擬帳戶結餘
	 */
	@Column(name = "VIRTUAL_BALANCE", columnDefinition = "numeric(10,2)")
	private BigDecimal virtualBalance;

	/**
	 * bonus最後更新日期
	 */
	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "BONUS_LAST_UPDATE_TIME")
	private Date bonusLastUpdTime;

	/**
	 * 需支付的订单數
	 */
	@Column(name = "ORDER_TO_PAY", columnDefinition = "numeric(10,2)")
	private BigDecimal orderToPay = new BigDecimal(0);

	/**
	 * 已回答的商品提问數
	 */
	@Column(name = "REPLIED_PRODUCT_QUESTION", columnDefinition = "numeric(10,2)")
	private BigDecimal repliedProductQuestion = new BigDecimal(0);

	/**
	 * 发问中的商品提问數
	 */
	@Column(name = "ASKED_PRODUCT_QUESTION", columnDefinition = "numeric(10,2)")
	private BigDecimal askedProductQuestion = new BigDecimal(0);

	/**
	 * 客服与问答:两週内已回答數
	 */
	@Column(name = "REPLIED_CRM", columnDefinition = "numeric(10,2)")
	private BigDecimal repliedCRM = new BigDecimal(0);

	/**
	 * 客服与问答:發問中的提問數
	 */
	@Column(name = "ASKED_CRM", columnDefinition = "numeric(10,2)")
	private BigDecimal askedCRM = new BigDecimal(0);

	public BigDecimal getAskedProductQuestion() {
		return askedProductQuestion;
	}

	public BigDecimal getBonusBalance() {
		return bonusBalance;
	}

	public Date getBonusLastUpdTime() {
		return bonusLastUpdTime;
	}

	public BigDecimal getGiftcardBalance() {
		return giftcardBalance;
	}

	public String getMemberID() {
		return memberID;
	}

	public BigDecimal getOrderToPay() {
		return orderToPay;
	}

	public BigDecimal getPointBalance() {
		return pointBalance;
	}

	public BigDecimal getRepliedCRM() {
		return repliedCRM;
	}

	public BigDecimal getRepliedProductQuestion() {
		return repliedProductQuestion;
	}

	public BigDecimal getVirtualBalance() {
		return virtualBalance;
	}

	public void setAskedProductQuestion(BigDecimal askedProductQuestion) {
		this.askedProductQuestion = askedProductQuestion;
	}

	public void setBonusBalance(BigDecimal bonusBalance) {
		this.bonusBalance = bonusBalance;
	}

	public void setBonusLastUpdTime(Date bonusLastUpdTime) {
		this.bonusLastUpdTime = bonusLastUpdTime;
	}

	public void setGiftcardBalance(BigDecimal giftcardBalance) {
		this.giftcardBalance = giftcardBalance;
	}

	public void setMemberID(String memberID) {
		this.memberID = memberID;
	}

	public void setOrderToPay(BigDecimal orderToPay) {
		this.orderToPay = orderToPay;
	}

	public void setPointBalance(BigDecimal pointBalance) {
		this.pointBalance = pointBalance;
	}

	public void setRepliedCRM(BigDecimal repliedCRM) {
		this.repliedCRM = repliedCRM;
	}

	public void setRepliedProductQuestion(BigDecimal repliedProductQuestion) {
		this.repliedProductQuestion = repliedProductQuestion;
	}

	public void setVirtualBalance(BigDecimal virtualBalance) {
		this.virtualBalance = virtualBalance;
	}

	public BigDecimal getAskedCRM() {
		return askedCRM;
	}

	public void setAskedCRM(BigDecimal askedCRM) {
		this.askedCRM = askedCRM;
	}
}